<template>
	<view>
		<view class="fixed fixed-top z-99999"  v-if="scrollTop === true" >
			<common-top :textContent="textContent"></common-top>
		</view>
		<xsuu-swiper :swiperItems="swiperItems" :margin="swiperMargin" :borderRadius="swiperBorderRadius" :btnLink="btnLink"></xsuu-swiper>
		<view class=" clear"></view>
		<view class="p-15 h bg-fff">
			<view class="text-blue b">重点企业分类</view>
			<view class="item-project-type">
				<view class="item-box-2" v-for="item in projectTpe">
					<view class="item-box">
						<view class="img-box">
							<image :src="item.img" mode="widthFix" class="img"></image>
						</view>
						<view class="text-box">{{item.name}}</view>
					</view>
				</view>
			</view>
		</view>
		<view class="clear h-30"></view>
		<view class="h pt-30 pl-30 pr-30 pb-20 bg-fff">
			<view class="uni-center b contect-title">联系我们</view>
			<view class="clear h-50"></view>
			<view class="index-map-box">
				<map
					style="width:100%;height:100%;"
					:scale="scale"
					:latitude="latitude"
					:longitude="longitude"
					:markers="markers"
				>
				</map>
			</view>
			<view class="clear h-10"></view>
			<view class="contect-list">
				<view :class="'icon-'+item.icon" v-for="item in contect">{{item.name}}</view>
			</view>
		</view>
		<view class="clear h-30"></view>
		<view class="h pt-30 pl-30 pr-30 bg-fff">
			<view class="uni-center b contect-title">我有投资意向</view>
			<view class="clear h-50"></view>
			<view class="write-box">
				<view class="item-list">
					<view><text class="red">*</text> 姓名</view>
					<view class="input-box"></view>
				</view>
				<view class="item-list">
					<view><text class="red">*</text> 联系电话</view>
					<view class="input-box"></view>
				</view>
				<view class="item-list">
					<view><text class="red">*</text> 公司名称</view>
					<view class="input-box"></view>
				</view>
				<view class="item-list">
					<view><text class="red">*</text> 留言</view>
					<view class="input-box input-message"></view>
				</view>
				<view class="item-list">
					<view class="btn-box">马上提交</view>
				</view>
			</view>
		</view>
		<view class="clear"></view>
		<view class="content-height"></view>
	</view>
</template>

<script>
import CommonTop from "@/components/common-files/common-top.vue"
import XsuuSwiper from "@/components/Xss-swiper/Xsuu-swiper.vue"
export default {
	components: {
		CommonTop,
		XsuuSwiper
	},
	data() {
		return {
			scrollTop:false,
			textContent:'达川招商局',
			paddingLeft:30,
			btnLink:false,
			swiperBorderRadius:0,
			swiperMargin:0,
			swiperItems:[
				 {
					"img": "../../static/banner-01.jpg",
					"title": "成都市锦江区东城拐下街8号5栋3单元1层1号住宅",
					"address": "如果需要打包成iOS 或者Android 原生项目需要集成原生插件",
					"area": 365.3,
					"url": "/pages/product/info",
					"presentMoney": 9876543210.65,
					"unit":"元",
					"type":"商铺"	,
					"status":1				
				 },
				 {
					"img": "https://gimg2.baidu.com/image_search/src=http%3A%2F%2Fs1.xchuxing.com%2Fxchuxing%2Fforum%2F201607%2F27%2F185524zj7wog6qizk9o90k.jpg&refer=http%3A%2F%2Fs1.xchuxing.com&app=2002&size=f9999,10000&q=a80&n=0&g=0n&fmt=jpeg?sec=1619914861&t=4c64a4a5cec709f9d03507b793546646",
					"title": "包月低至9.9元",
					"address": "原生项目需要集成原生插件",
					"area": 365.3,
					"url": "/pages/product/info",
					"presentMoney": 210.65,
					"unit":"万元",
					"type":"商铺"	,
					"status":2
				 }
			],
			projectTpe:[
				{
					name:'丘区农机类',
					"img": "../../static/project-type-01.jpg"
				},
				{
					name:'农业和食品保健类',
					"img": "../../static/project-type-02.jpg"
				},
				{
					name:'康养文旅类',
					"img": "../../static/project-type-03.jpg"
				},
				{
					name:'生态工业类',
					"img": "../../static/project-type-04.jpg"
				},
				// {
				// 	name:'现代服务业类',
				// 	"img": "../../static/project-type-05.jpg"
				// }
			],
			scale: 15,
			latitude: 39.909,
			longitude: 116.39742,
			markers: [],
			items: [
				{
					id: 'XKD13V6-5D62-VP08-1',
					name: '土地资产名称',
					latitude: 39.9085,
					longitude: 116.39747,
					iconPath: '../../static/icon-map.png',
				}
			],
			contect:[
				{
					name:'四川省达州市达川区双林街道撒旦法发色的风格和',
					icon:'address'
				},
				{
					name:'028-88888888',
					icon:'phone'
				},
				{
					name:'达川投促中心招商中心',
					icon:'unit'
				}
			]
		}
	},
	onLoad: function() {
		this.markers = this.items;
		this.items.forEach(i => {
			i.latitude = i.latitude;
			i.longitude = i.longitude;
			i.iconPath = '../../static/icon-map.png';
			i.width = 30;
			i.height = 43;
			i.callout = {
				content: i.name,
				color: 'white',
				fontSize: 14,
				borderRadius: 5,
				bgColor: 'rgba(0,0,0,0.5)'
			}
		})
	},
	methods: {

	},
	onPageScroll(e) {
		this.scrollTop = e.scrollTop;
		if( this.scrollTop > 100 ){
			this.scrollTop = true
		} else{
			this.scrollTop = false
		}
		// this.scrollTop = e.scrollTop;
		// console.log(this.scrollTop)
	}
}
</script>

<style>
</style>
